package com.qf.test.service;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.qf.test.mapper.DtsGoodsMapper;
import com.qf.test.pojo.DtsGoods;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class GoodsServiceImpl implements GoodsService {
    @Autowired
    private DtsGoodsMapper dtsGoodsMapper;
    @Override
    public int countGoods() {
        QueryWrapper<DtsGoods> queryWrapper = new QueryWrapper<>();
        queryWrapper.eq("deleted",false);
        Integer count = dtsGoodsMapper.selectCount(queryWrapper);
        return count;
    }
}
